<?php /*
$ctrl=new MainController();
$ctrl->run();
function __autoload($myClass){
	require_once ("application/controllers/".$myClass.".php");
	require_once 'technics//DAO.php';
}
Class MainController{
	private $urlParts;
	
	/*public function __construc(){
		if(!$this->isValid())
			$this->onInvalidControl();
		
	}
	
	public function index(){
		
	}
	
	public function isValid(){
		return (isset($_SESSION['user']));
	}*/
	
	/*public function run(){
		session_start();
		$url= $_GET['c'];
		$this->urlParts=explode("/",$url);//explose l'url en plusieurs partie a chaque slash, sera inser� dans un array
		$u=$this->urlParts;
		$urlSize=sizeof($this->urlParts);
		
		if(class_exists($this->urlParts[0])){
			$obj = new $this->urlParts[0](); //premiere partie de l'url [0]
			switch($urlSize){
				case 1:
					$obj->index();
			break;
				case 2:
					$obj->$u[1]();
			break;
				default:
					$obj->$u[1](array_slice($u, 2));
				break;
		}	
	}
}
}


?>